
using System;

namespace raycsharp
{


	public class Grid
	{
		public Vector position { get; set; }
		public Vector x { get; set; }
		public Vector y { get; set; }
		public Vector z { get; set; }
		public uint height { get; set; }
		public uint width { get; set; }
		
		public Grid (uint _width, uint _height, Vector _position, Vector _x, Vector _y, Vector _z) {
			width = _width;
			height = _height;
			position = _position;
			x = _x;
			y = _y;
			z = _z;
		}
		public Vector projection_transformation(uint _pixel_x,uint _pixel_y) {
			double px = ((2.0/width)*_pixel_x) - 1.0;
			double py = ((2.0/height)*_pixel_y) - 1.0;
			return x*px + y*py;
		}

	}
}

